#ifndef MYQTEXTEDIT_H
#define MYQTEXTEDIT_H

#include <QTextEdit>
struct MyQTextEditPrivate;

class MyQTextEdit:public QTextEdit
{
    Q_OBJECT

public:
    MyQTextEdit(QWidget *parent = nullptr);
    ~MyQTextEdit();
    void SetPlaySpeed(int speed);
    void SetText(QString text);
    void ApendText(QString appendText);
    void DisplayText(QString);
    bool CreateTimer(int);
    bool CancleTimer();
    void CleanEdit();
    void SetPause(bool state);
private:
    void timerEvent(QTimerEvent *event) override;
    MyQTextEditPrivate* _p;
};

#endif // MYQTEXTEDIT_H
